Upgrade RocksDB JNI to 10.10.1.1 while preserving 7.9.2 index compatibility - #4886
Merged
Merged
Conversation
lhotari
marked this pull request as ready for review
September 10, 2026 18:47
merlimat
approved these changes
Sep 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
Upgrade RocksDB JNI from 9.9.3 to 10.10.1.1, the latest version published on Maven Central as checked on 2026-09-10, while preserving the bookie's RocksDB index data compatibility with 7.9.2. BookKeeper 4.17.0 uses 7.9.2; later 4.17.x patches use 7.10.2, so 7.9.2 is the conservative compatibility baseline for Pulsar 4.0.x deployments.
Upstream's latest release is 11.8.1, but its rocksdbjni artifact is not available on Maven Central. This PR deliberately targets the latest consumable JNI release, rather than introducing an unresolvable dependency.
The JNI-only 10.10.1.1 release fixes the Windows native-symbol failure reported in RocksDB #14537. Its Java sources are unchanged from 10.10.1; upstream RocksDB source/documentation links therefore retain the v10.10.1 tag.
Changes
rocksdb.versionto 10.10.1.1 and update RocksDB artifact/source references in both binary distribution LICENSE files.format_version=5in all threeconf/*_rocksdb.conf.defaulttemplates and document the benefits and minimum reader versions of formats 6 and 7.track_and_verify_wals=falseto preserve WAL recovery by 7.9.2, with comments explaining when the newer integrity checks can be enabled.Backwards compatibility at the storage format level
The default bookie ledger-metadata and entry-location indexes remain readable and writable by RocksDB 7.9.2 after upgrading to 10.10.1.1. No index migration or rewrite is required for this configuration. This concerns RocksDB indexes; the BookKeeper journal and entry-log formats are unchanged.
track_and_verify_wals=false(also the native default used by the Java fallback). The feature introduced in 9.11 writes predecessor-WAL records that the 7.9.2 reader does not recognize. Existing ordinary write batches remain recoverable.Storage compatibility does not mean configuration files can be copied unchanged between releases: 7.9.2 rejects the new
track_and_verify_walsoption even when false. Use the older release's configuration on rollback, retaining compatible format/compression settings; do not load the newer generatedOPTIONS-*file into the older strict parser. Operators using custom options must preserve these constraints. Loweringformat_versiondoes not convert SSTs already written in a newer format; those need rewriting with a capable RocksDB version before rollback. Enabling newer WAL records likewise cannot be undone merely by changing the option back.This compatibility statement is scoped to the bookie's
KeyValueStorageRocksDBindexes and their supplied/default settings, not the separate stream state-store implementation or arbitrary opt-in RocksDB features.Release-note review
Reviewed the published release notes since 9.9.3 and cumulative history through 11.8.1, including patch-release notes. Relevant changes:
max_compaction_bytesmore strictly.fail_if_options_file_errorandmax_write_buffer_number_to_maintain.Validation
mvn -B -pl bookkeeper-server,stream/statelib -am test -Dtest=KeyValueStorageRocksDBTest,KeyValueStorageTest,EntryLocationIndexTest,LedgerMetadataIndexTest -Dsurefire.failIfNoSpecifiedTests=falsemvn -B -pl bookkeeper-server -am checkstyle:check apache-rat:check.b787f29832: all test groups, integration and backward-compatibility tests, Java 17/21 compatibility, Windows/macOS builds, binary license validation, and the aggregate CI check. CodeQL also passed. No flaky-test retries were needed for this commit.